package com.csi.bumblebee.util;

import java.text.SimpleDateFormat;
import java.util.Date;

/**
 * 生成id工具类
 *
 * @author HUOJT
 */
public class IdUtil {

    /**
     * 得到随机的id
     *
     * @param pre id前缀
     * @return id
     */
    public static String getString(String pre) {
        SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyyMMddHHmmss");
        String time = simpleDateFormat.format(new Date());
        int random = (int) (Math.random() * (89999)) + 10000;
        return pre + time + random;
    }




}
